import request from '@/utils/request'
const baseUrl = '/eduservice/teacher'
export default {
    /**
     * 
     * @param {Object} queryParam 
     * @param {int} page 
     * @param {int} limit 
     * @returns 
     */
    getListTeacher(queryParam, page, limit) {
        return request({
            url:  baseUrl + `/pageListEntityQuery/${page}/${limit}`,
            method: 'post',
            data: {...queryParam}
        })
    },
    deleteEntityById(id){
        return request({
            url:  baseUrl + `/deleteEntityById/${id}`,
            method: 'delete',
        })
    },
    saveEntity(entity){
        return request({
            url:  baseUrl + `/saveEntity`,
            method: 'post',
            data: {...entity}
        })
    },
    updateEntity(entity){
        return request({
            url:  baseUrl + `/updateEntity`,
            method: 'put',
            data: {...entity}
        })
    },
    getEntity(id){
        return request({
            url:  baseUrl + `/getEntity/${id}`,
            method: 'get',
        })
    },
    listEntity(){
        return request({
            url:  baseUrl + `/listEntity`,
            method: 'get',
        })
    }
}